<html>
<script type="text/javascript">
var xhr = new XMLHttpRequest();
xhr.open('GET', 'http://192.168.168.126:8080/code'); // 换为自己的接口地址
xhr.send(null);
xhr.onload = function(e) {
    var xhr = e.target;
    console.log(xhr.responseText);
}
</script>
</html>